<?PHP
$news = new content;
$news->content_type=2;
$news->content_category=get_category_by_name('company events');
$news->options['order'][0]='content_start';
$news->options['order'][1]='DESC';
// process start and end times
$q[0]='content_start';
$q[1]=date("Y-m-d");
$q[2]='<=';
$news->where[]=$q;
$q[0]='content_end';
$q[1]=date("Y-m-d");
$q[2]='>=';
//$e['content_start']=date("Y-m-d");
$news->where[]=$q;

$data=$news->get_content();
?>